extends Control

@onready var character_name = $CharacterPanel/CharacterName

func _init() -> void:
	#当玩家信息发生改变
	CharacterData.onPlayerDataChange.connect(onPlayerDataChange)
	
func  _ready() -> void:
	#加载信息
	CharacterData.load_character_data();

func onPlayerDataChange():
	character_name.text = "%s" %CharacterData.get_character_data()['character_name']
	

# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
	pass
